random walk & Fibo

import numpy as np
import matplotlib.pyplot as plt
if __name__=="__main__":
tx=[]
ty=[]
for i in range(10000):
pos=[0, 0]
for i in range(100):
rn=np.random.randint(4)
if(rn==0): pos[0]+=1
elif(rn==1): pos[0]-=1
elif(rn==2): pos[1]+=1
else: pos[1]-=1
tx.append(pos[0])
ty.append(pos[1])
plt.scatter(tx, ty)
plt.grid(True)
plt.show()
def facto(n):
if n!=1:
return n*facto(n-1)
return 1
facto(10)
if __name__=="__main__":
a=[1, 1]
N=int(input("#NUM: "))
while(len(a)!=N):
a.append(a[-2]+a[-1])
print(a)